import { RouteRecordRaw, RouterView } from 'vue-router'
import layout from '@/layout/index.vue'
import { Lock } from '@element-plus/icons'

const routes: RouteRecordRaw = {
  path: '/permission',
  name: 'Permission',
  component: layout,
  meta: { icon: Lock, noCache: true },
  children: [
    {
      path: 'admin',
      name: 'Admin',
      component: () => import('@/pages/permission/admin/index.vue'),
    },
    {
      path: 'role',
      name: 'Role',
      component: () => import('@/pages/permission/role/index.vue'),
    },
    {
      path: 'rule',
      name: 'Rule',
      component: () => import('@/pages/permission/rule/index.vue'),
    },
  ],
}

export default routes
